package com.qingke.easyjava.xmlconverter;

import java.util.ArrayList;
import java.util.List;

import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement;

@XmlRootElement(name = "regions")
@XmlAccessorType(XmlAccessType.FIELD)
public class RegionList {

    @XmlElement(name = "region")
    private List<Region> regions;
    
    public RegionList(){
        regions = new ArrayList<Region>();
    }

    public List<Region> getRegions() {
        return regions;
    }

    public void setRegions(List<Region> regions) {
        this.regions = regions;
    }
    
    public void addRegion(Region region) {
        this.regions.add(region);
    }
    
}
